import http from '@/utils/fetch'

/**
 * 供应商管理-供应商列表
 */
// 获取供应商列表
export function getMerchantList(params) {
  return http.post('/Admin/Merchant/getMerchantList', params)
}
// 查看供应商信息
export function getSupplierInfo(id) {
  return http.get('/Admin/Supplier/supplierInfoById', { id: id })
}
//是否移交催收
export function whetherHandOver(params) {
  return http.post('/Admin/Supplier/whetherHandOver', params)
}
// 获取省份列表
export function getProvinceList() {
  return http.get('/Admin/Supplier/getCompanyArea')
}
// 编辑供应商信息
export function editSupplier(params) {
  return http.post('/Admin/Supplier/editSupplierById', params, true)
}
// 获取区域二级列表
export function getCompanyArea(id) {
  return http.get('/Admin/Supplier/getSecondCompanyArea', { id: id })
}

// 获取租户列表
export function getRealList(params) {
  return http.get('/Admin/RealUser/getRealList', params)
}

// 群发短信
export function sendAllUser(params) {
  return http.post('/Admin/OrderController/SendAllUser', params)
}

// 租户加入黑名单
export function addBlack(params) {
  return http.post('/Admin/RealUserController/addBlackUser', params)
}

// 租户删除黑名单
export function deleteBlack(params) {
  return http.post('/Admin/RealUserController/deleteBlackUser', params)
}
// 根据商户ID进行关闭店铺
export function closeShopUser(params) {
  return http.post('/Admin/Supplier/closeShopUser', params)
}
// 根据商户ID进行开启店铺
export function openShopUser(params){
  return http.post('/Admin/Supplier/openShopUser', params)
}

// 根据商户ID进行限制单量
export function limitQuantity(params){
  return http.post('/Admin/Supplier/limitQuantity', params)
}